{template "mheader.html"}


<link href="{THEME_PATH}assets/mall/css/mall.css" rel="stylesheet" type="text/css" />

<form action="" class="form-horizontal" method="post" name="myform" id="myform">
    {dr_form_hidden()}
    <input type="hidden" name="ids[]" value="{$order.id}" />
    <div class="portlet bordered light">
        <div class="portlet-title">
            <div class="caption">
                <span class="caption-subject font-green">{$item.title}</span>
            </div>
        </div>
        <div class="portlet-body form">

            <div class="form-body">

                <div class="row">
                    <div class="col-md-6">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('订单编号')}</label>
                            <div class="col-md-7">
                                <p class="form-control-static"><a href="javascript:;" onclick="dr_iframe_show('{dr_lang("订单详情")}', '{dr_member_url("order/sell/show", ["id"=>$order.id])}', '90%', '90%')">{$order.sn}</a></p>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                    <div class="col-md-6">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('下单时间')}</label>
                            <div class="col-md-7">
                                <p class="form-control-static">{dr_date($order.inputtime, 'Y-m-d H:i:s', 'red')}</p>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                <div class="row">
                    <div class="col-md-6">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('申请时间')}</label>
                            <div class="col-md-7">
                                <p class="form-control-static">{dr_date($item._inputtime, 'Y-m-d H:i:s', 'red')}</p>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                    <div class="col-md-6">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('申请账号')}</label>
                            <div class="col-md-7">
                                <p class="form-control-static">{$item.username}</p>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                <!--/row-->
                <!--/row-->
                <div class="row">
                    <div class="col-md-6">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('申请类型')}</label>
                            <div class="col-md-7">
                                <p class="form-control-static" style="cursor: pointer" >{order_service_type($item.type)}</p>
                            </div>
                        </div>
                    </div>
                    <div class="col-md-6">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('申请状态')}</label>
                            <div class="col-md-7">
                                <p class="form-control-static" >{order_service_status($item.status)}</p>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                <!--/row-->
                <div class="row">
                    <div class="col-md-6">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('申请说明')}</label>
                            <div class="col-md-7">
                                <p class="form-control-static" style="cursor: pointer" >{nl2br($item.remark)}</p>
                            </div>
                        </div>
                    </div>
                    <div class="col-md-6">
                        <div class="form-group row">
                            {loop $item.images.file $i $t}
                            <div class="col-sm-6 col-md-3">
                                <a href="javascript:;" onclick="dr_show_image('{$item[images][title][$i]}', '{dr_get_file($t)}')" class="thumbnail"><img src="{dr_thumb($t, 200,200)}" > </a>
                            </div>
                            {/loop}
                        </div>
                    </div>
                    <!--/span-->
                </div>

            </div>
        </div>
    </div>
    <div class="portlet bordered light  myfbody">
        <div class="portlet-title">
            <div class="caption">
                <span class="caption-subject font-green">{dr_lang('受理情况')}</span>
            </div>
        </div>
        <div class="portlet-body form">

            <div class="form-body">


                <!--/已提交的情况下-->
                {if $item.type == 1}
                <div class="row fc-mall-col-2">
                    <div class="col-md-12">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('退款金额')}</label>
                            <div class="col-md-7">
                                <label> <input class="form-control" name="data[money]" value="{$item.money}" type="text"></label>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                {elseif $item.type == 2}
                <div class="row fc-mall-col-2">
                    <div class="col-md-12">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('退款金额')}</label>
                            <div class="col-md-7">
                                <label> <input class="form-control" name="data[money]" value="{$item.money}" type="text"></label>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                <div class="row fc-mall-col-2">
                    <!--/span-->
                    <div class="col-md-12">
                        <div class="form-group">
                            <label class="col-md-3 control-label">{dr_lang('退货地址')}</label>
                            <div class="col-md-7">
                                <textarea class="form-control" name="system[address]" rows="5">{$address}</textarea>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                {elseif $item.type == 3}
                <div class="row fc-mall-col-2">
                    <!--/span-->
                    <div class="col-md-12">
                        <div class="form-group">
                            <label class="col-md-3 control-label">{dr_lang('换货地址')}</label>
                            <div class="col-md-7">
                                <textarea class="form-control" name="system[address]" rows="5">{$address}</textarea>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                {/if}

                {if $item.myinfo.kdmc}
                <div class="row fc-mall-col-2">
                    <div class="col-md-12">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('快递名称')}</label>
                            <div class="col-md-7">
                                <p class="form-control-static" >{$item.myinfo.kdmc}</p>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                <div class="row fc-mall-col-2">
                    <div class="col-md-12">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('快递单号')}</label>
                            <div class="col-md-7">
                                <p class="form-control-static" >{$item.myinfo.kddh}</p>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                {if $item.type == 3}
                <div class="row fc-mall-col-2">
                    <div class="col-md-12">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('寄回地址')}</label>
                            <div class="col-md-7">
                                <p class="form-control-static" >{nl2br($item.myinfo.address)}</p>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                {/if}
                {/if}

                <div class="row fc-mall-col-2">
                    <div class="col-md-12">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('处理状态')}</label>
                            <div class="col-md-7">

                                <div class="mt-radio-inline">
                                    <label class="mt-radio mt-radio-outline"><input name="status" type="radio" value="1" /> {dr_lang('通过')} <span></span></label>
                                    <label class="mt-radio mt-radio-outline"><input name="status" type="radio" value="2"  /> {dr_lang('拒绝')} <span></span></label>
                                </div>


                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>

                {if $item.type == 3}
                <div class="row fc-mall-col-2">
                    <div class="col-md-12">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('选择物流')}</label>
                            <div class="col-md-5">
                               <label> <select class="form-control" name="system[id]">
                                   <option value="0"> -- </option>
                                   {loop $delivery_corp $t}
                                   <option value="{$t.id}" {if $t.id== $item.system.id} selected{/if}>{$t.name}</option>
                                   {/loop}
                               </select></label>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                <div class="row fc-mall-col-2">
                    <div class="col-md-12">
                        <div class="form-group row">
                            <label class="col-md-3 control-label">{dr_lang('运单编号')}</label>
                            <div class="col-md-5">
                                <input class="form-control" name="system[sn]" value="{$item.system.sn}" type="text">
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>
                {/if}

                <div class="row fc-mall-col-2">
                    <!--/span-->
                    <div class="col-md-12">
                        <div class="form-group">
                            <label class="col-md-3 control-label">{dr_lang('拒绝理由')}</label>
                            <div class="col-md-7">
                                <textarea class="form-control" name="data[sysnote]" rows="5">{$item.sysnote}</textarea>
                            </div>
                        </div>
                    </div>
                    <!--/span-->
                </div>



                <!--/row-->
            </div>
        </div>
    </div>



    <div class="portlet-body form myfooter">
        <div class="form-actions text-center">
            <label><a onclick="dr_ajax_submit('{dr_now_url()}', 'myform', '2000')" class="btn green"> <i class="fa fa-edit"></i> {dr_lang('提交')}</a></label>
            <label><a href="{$reply_url}" class="btn yellow"> <i class="fa fa-mail-reply"></i> {dr_lang('返回')}</a></label>
        </div>
    </div>
</form>

<script>
    function dr_show_image(title, url) {
        layer.load(2, {
            shade: [0.3,'#fff'], //0.1透明度的白色背景
            time: 1000
        });
        layer.open({
            type: 1,
            title: title,
            scrollbar: false,
            resize: true,
            maxmin: true, //开启最大化最小化按钮
            shade: 0,
            area: ['70%', '70%'],
            success: function(layero, index){
                layer.closeAll('loading');
            },
            content: '<p style="text-align: center"><img src="'+url+'"></p>'
        });
    }
</script>
{template "mfooter.html"}